package cn.mw.cmdb.template.service;


import cn.mw.cmdb.template.entity.*;
import cn.mw.cmdb.template.entity.convert.MwHostGroupConvertDto;
import cn.mw.cmdb.template.entity.convert.MwTemplateConvertOne;
import cn.mw.cmdb.template.param.MwTemplateConfigurationParam;
import cn.mw.cmdb.template.param.TemplateParam;
import jakarta.servlet.http.HttpServletResponse;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

public interface MwTemplateConfigurationService {

    List<MwTemplateConfigurationDto> getTemplateInfoByServerId(MwTemplateConfigurationParam param) throws Exception;

    void createTemplateInfo(TemplateParam templateParam);

    void updateTemplateInfo(TemplateParam templateParam) throws Exception;

    void deleteTemplateInfo(MwTemplateConfigurationParam param) throws Exception;

    List<MwHostGroupConvertDto> getHostGroup(MwTemplateConfigurationParam param) throws Exception;

    MwTemplateConvertOne getTemplateInfoById(MwTemplateConfigurationParam param);

    Object getTemplateDetailInfo(MwTemplateConfigurationParam param);
    void addTemplateDetailInfo(MwTemplateConfigurationParam param);
    void updateTemplateDetailInfo(MwTemplateConfigurationParam param);
    void deleteTemplateDetailInfo(MwTemplateConfigurationParam param);
    Object selectTemplateDetailById(MwTemplateConfigurationParam param);

    List<DropDownDto> getMonitorItemTypeInfo();

    List<MwZabbixDetectorDto> getZabbixDetectorInfo(MwTemplateConfigurationParam param) throws Exception;

    void exportTemplateData(MwTemplateConfigurationParam param, HttpServletResponse response) throws Exception;

    void importTemplateData(MwTemplateConfigurationParam param, MultipartFile file) throws Exception;

    /**
     * 获取触发器分组信息
     */
    List<TriggerGroupDto> getTriggerGroupInfo(MwTemplateConfigurationParam param) throws Exception;

    /**
     * 获取zabbix函数信息
     * @return
     */
    List<FunctionClassifyDto> getZabbixFunctionInfo();

}
